<template>
  <div>
    <FormTitle title="仓库信息"/>
    <div class="flex flex-wrap">
      <Descriptions label-width="118px" v-for="item in warehouseInfo" :key="item.label" :label="item.label" :value="data?.[item.field] || '-'" />
    </div>
  </div>
</template>

<script setup>
import FormTitle from '@/components/XForm/FormTitle.vue'
import Descriptions from '@/components/Descriptions/index.vue'

const props = defineProps({
  data: {
    type: Object,
    default: () => ({}),
  },
})

const warehouseInfo = [
  { label: '退回仓库', field: 'exchange_warehouse_name' },
  { label: '国家', field: 'warehouse_country_name' },
  { label: '邮编', field: 'warehouse_post_code' },
  { label: '联系人', field: 'warehouse_contact_person' },
  { label: '地址', field: 'warehouse_address' },
]
</script>
